package net.towee.client.event.core;

import java.util.List;

import net.towee.model.repo.DocumentIdentity;

import com.google.gwt.event.shared.GwtEvent;

public class DocumentDeletedEvent extends GwtEvent<DocumentDeletedHandler> {
	public static Type<DocumentDeletedHandler> TYPE = new Type<DocumentDeletedHandler>();
	private final List<DocumentIdentity>result;
	private final boolean local;
	
	public DocumentDeletedEvent(List<DocumentIdentity> result2, boolean local) {
		this.local = local;
		this.result = result2;
	}

	@Override
	public com.google.gwt.event.shared.GwtEvent.Type<DocumentDeletedHandler> getAssociatedType() {
		return TYPE;
	}

	@Override
	protected void dispatch(DocumentDeletedHandler handler) {
		handler.onDocumentDeleted(result, local);
	}

}
